home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Controls / Visual Basic Controls.iso / vbcontrol / pgrdll / readme.txt < prev    next >
Text File  |  1999-07-23  |  10KB  |  237 lines

  1. PagerDll Technical Documentationá 
  2.  
  3. Description of the files included with the PagerDll.
  4.  
  5. á
  6.  
  7. Document Updated: June 26, 1999
  8.  
  9. Version 1.00
  10.  
  11. readme.htm   Documents the DLL functions.
  12. readme.txt   This file.
  13. PagerDll.dll The Pager Dll for sending pages.This should be copied to your
  14.              project or the windows directory.
  15. PagerDll.lib Import library for the Dll. When compiling a in C/C++ environment
  16.              include this library in the link path and PagerDll.h as the header
  17.              file for your source files.
  18. PagerDll.h   C/C++ header file containing the declarations for the Dll functions.
  19. PagerDll.bas A Visual Basic .bas file containing the declarations for the Dll
  20.              functions. Include this in your Modules section of your Visual Basic Project.
  21. PagerDll.def A text file containing the ordinal numbers associated with the Dll functions.
  22.              This is mainly for programmers using the Dll at run time using the LoadLibrary
  23.              function. The import library does not have to linked at compile time in this case.
  24. license.txt  License agreement for the Dll. 
  25.  
  26.  
  27.  
  28. ------------------------------------------------------------------------
  29.  
  30.  
  31. The syntax used in the following constants, structures and functions is based on C . 
  32.  
  33. int refers to a 4 byte integer
  34. short int refers to a 2 byte integer
  35. float refers to a 4 byte floating point
  36. char refers to a single byte.
  37.  
  38.  
  39.  
  40. //Constants 
  41.  
  42. COM_ERROR          -101
  43. MEMORY_ERROR       -102
  44. COM_OPEN           -103
  45. COM_CLOSE          -104
  46. INVALID_COMPORT    -105
  47. INVALID_PHONENO    -106
  48. STRING_TOOLONG     -107
  49. STRLEN_ERR         -108
  50. BAUDRATE_ERR       -109
  51. PROTOCOLTYPE_ERR   -110
  52. MSG_ERR            -111
  53. BLOCKSIZE_ERR      -112
  54. FILENAME_ERR       -113
  55. PARAMREQUIRED_ERR  -114
  56. CONNECT_ERR        -115
  57. IDRECEIVE_ERR      -116
  58. INVALID_DELAY      -117
  59. ------------------------------------------------------------------------
  60.  
  61.  
  62. Return Values 
  63.  
  64. COM_ERROR indicates that there was a problem in communication over the serial port.
  65.  
  66. 1 usually indicates success
  67.  
  68. -1 usually indicates failure.
  69.  
  70.  
  71.  
  72. ------------------------------------------------------------------------
  73.  
  74. Functions
  75.  
  76. GetDllVersion
  77. WriteToLogFile
  78. SendNumericPage
  79. SendAlphaPage
  80. SendAlphaPageAdvanced
  81. SendAlphaPageByEmail
  82. ------------------------------------------------------------------------
  83.  
  84.  
  85. float GetDllVersion ();
  86. Description
  87. Gets the Dll version number.
  88. Return Values
  89. 1 if successful
  90.  
  91. ------------------------------------------------------------------------
  92.  
  93. short int WriteToLogFile (char EnableLogging);
  94. Parameters
  95. EnableLogging //0 to disable logging and 1 to enable logging
  96. Description
  97. Enables or disables the logging of events.
  98. Return Values
  99. 1 if successful
  100. -1 if unsuccessful
  101.  
  102.  
  103. ------------------------------------------------------------------------
  104.  
  105. short int SendNumericPage(short int ComPort, char* PagerNo, char* PinNo, char* message, short int PDelay, char PulseDial);
  106. Parameters
  107. ComPort // Serial Commmunication port of your modem.
  108. PagerNo //Phone number of your Pager.
  109. PinNo // Pin number if you have one otherwise enter NULL.
  110. message //Numeric message. Limit is 250 characters.
  111. PDelay //The time in seconds to wait after dialing the number.
  112. PulseDial //0 for Tone Dial and 1 for Pulse Dial. 
  113. Description
  114. Use the SendNumericPager to send a numeric message to a numeric Pager. The PDelay can vary
  115. for different pagers but is usually withing the range 6-10 seconds. Try increasing this
  116. number if you are not receiving messages. You can also obtain an estimate of what this
  117. value should be by dialing the Pager number from a phone and then note down the time till
  118. the operator's voice comes telling you to enter the message. This function cannot tell whether
  119. the message was received successfully by the Pager.
  120. Return Values
  121. INVALID_PHONENO Phone number string is blank.
  122. INVALID_COMPORT An invalid comp port number was entered.
  123. STRING_TOOLONG Message string is too long. There is usually a limit on the dial string of the
  124. modem. Also the total length of the phone number stirng, message string and the pin number
  125. string should not exceed 255.
  126. COM_OPEN Error opening the com port.
  127. COM_ERROR Error in communicating over the serial port.
  128. COM_CLOSE Error in closing the serial port.
  129.  
  130.  
  131. ------------------------------------------------------------------------
  132.  
  133. short int SendAlphaPage(short int comport, char* PagerNumber, char* PagerAccessNumber, char* message, char PulseDial);
  134. Parameters
  135. comport // Serial Commmunication port of your modem.
  136. PagerNumber //Phone number of your Pager.
  137. PagerAccessNumber // Pin number of your Pager.
  138. message //Text message. Limit is 250 characters.
  139. PulseDial //0 for Tone Dial and 1 for Pulse Dial. 
  140. Description
  141. SendAlphaPage is used to send text data to an alphanumeric Pager. This function uses the
  142. Manual protocol. You should use this function if you want to send a small string which will
  143. fit into a single page.
  144. Return Values
  145. STRLEN_ERR Length of message string exceeds 250 .
  146. INVALID_COMPORT Invalid com port number.
  147. PARAMREQUIRED_ERR The PagerNumber or PagerAccessNumber value is missing.
  148. MSG_ERR The message value is NULL .
  149. COM_OPEN Error opening the com port. 
  150. CONNECT_ERR Error in connecting to the Paging Carrier company. Either the number is busy or
  151. the right number was not given.
  152. IDRECEIVE_ERR Failed to receive request for the PagerAccess number.
  153. COM_CLOSE Error in closing the serial port.
  154.  
  155.  
  156.  
  157. ------------------------------------------------------------------------
  158.  
  159. short int SendAlphaPageAdvanced(short int comport, short int baudRate, char* PagerNumber, char* PagerAccessNumber, char TypeOfProtocol, char* fileName, char* message, short int blockSize, char PulseDial);
  160. Parameters
  161. comport // Serial Commmunication port of your modem.
  162. short int baudRate // The baudrate at which the alphanumeric protocols work is usually 1200.
  163. PagerNumber //Phone number of your Pager.
  164. PagerAccessNumber // Pin number of your Pager.
  165. TypeOfProtocol //There are 2 protocols used in the Dll. Value of TypeOfProtocol should be 0 for Manual Entry protocol and 1 for Automatic Entry protocol. 
  166. fileName // If the message is exceeds 250 characters then you should use a text file containing the message. 
  167. message //Text message. Limit is 250 characters.
  168. blockSize // Enter the max limit of characters your alphanumeric pager can accept. If the message is bigger than the blockSize then the message is broken at word boundaries and multiple pages are sent. 
  169. PulseDial //0 for Tone Dial and 1 for Pulse Dial. 
  170. Description
  171. SendAlphaPageAdvanced is used to send text data to an alphanumeric Pager. This function offers
  172. more options than the SendAlphaPage function. If a message is longer than the blocksize value
  173. then multiple pages are sent. The message can be taken from a text file by specifying the name
  174. in the fileName parameter. 
  175. Return Values
  176. STRLEN_ERR Length of message string exceeds 250 .
  177. INVALID_COMPORT Invalid com port number.
  178. PARAMREQUIRED_ERR The PagerNumber or PagerAccessNumber value is missing.
  179. MSG_ERR The message value is NULL .
  180. BAUDRATE_ERR Invalid baudrate entry.
  181. PROTOCOLTYPE_ERR Invalid value for the protocol.
  182. BLOCKSIZE_ERR Invalid value for the blocksize.
  183. COM_OPEN Error opening the com port. 
  184. CONNECT_ERR Error in connecting to the Paging Carrier company. Either the number is busy or the
  185. right number was not given.
  186. IDRECEIVE_ERR Failed to receive request for the PagerAccess number.
  187. COM_CLOSE Error in closing the serial port.
  188.  
  189.  
  190. ------------------------------------------------------------------------
  191.  
  192. short int short int SendAlphaPageByEmail(char* hostName, char* senderAddr, char* RecipientAddr, char* MsgID, char* Subject , char* message,char* fileName, short int blockSize ); ;
  193. Parameters
  194. hostName // Name of the mail server. Limit is 50 characters.
  195. senderAddr // Email address of the sender. Limit is 50 characters.
  196. RecipientAddr // Email address of the recipient. Limit is 50 characters.
  197. MsgID //Message Id of the Email. This parameter is optional. Limit is 50 characters.
  198. Subject, // Subj